package com.hkg.springbootsutdying.config;

import org.springframework.amqp.rabbit.annotation.RabbitListener;
import org.springframework.stereotype.Component;

/**
 * @ClassName : MessageListener
 * @Author : huaikaigang
 * @Date: 2020-07-23 16:21
 * @类描述:
 */
@Component
public class MessageListener {

    @RabbitListener(queues="topic.queue")
    public void topicListener(String msg){
        System.out.println("接收到的消息："+msg);
    }
}
